package com.lagou.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.lagou.entity.CustomUser;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface CustomUserMapper extends BaseMapper<CustomUser> {

    /**
     * 批量插入操作
     * @param customUserList customUserList
     */
    void insertBatch(@Param(value = "customUserList") List<CustomUser> customUserList);

    /**
     * 根据id 删除
     * @param id
     * @return
     */
    void deleteByPrimaryKey(Integer id);

    /**
     * 选择性插入
     * @param record
     * @return
     */
    void insertSelective(CustomUser record);

    CustomUser selectByPrimaryKey(Integer id);

    /**
     *
     * @param pageCurr 当前页
     * @param pageSize 当前页大小
     * @return List<CustomUser>
     */
    List<CustomUser> selectByPage(@Param(value = "pageCurr") int pageCurr, @Param(value = "pageSize") int pageSize);


    void updateByPrimaryKeySelective(CustomUser record);

    void updateByPrimaryKey(CustomUser record);
}